package cn.edu.ldu.communityqa.communityqa.controller;

import cn.edu.ldu.communityqa.communityqa.entity.Msg;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/api/hello")
public class HelloController {
    @GetMapping
    public String hello(){
        return "hello world";
    }

    @GetMapping("/msg")
    public ResponseEntity<Msg> msg(){
        return Msg.responseEntity("hello world");
    }
}
